<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@page import="java.util.*" %>
<%
	String path = request.getContextPath();
	String uuid = UUID.randomUUID().toString();
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<script>
	//javascript模拟超链接操作
	function on(){
		window.location.href="<%=path %>/args/newJieForm.jsp?name=kitty&age=5";
	}
	
	//javascript模拟表单提交,推荐使用
	function en(){
		document.form1.action="<%=path %>/args/jieForm.jsp?name=wanger";
		document.form1.submit();
	}
</script>
<body>
<form name="form1" action="<%=path %>/args/jieForm.jsp?name=wanger" method="post">
	<input type="text" name="username" value=""><br>
	<input type="password" name="password" /><br>
	<input type="hidden" name="hide" value="<%=uuid%>">
	<hr>
	<input type="checkbox" name="chi" value="鲤鱼">鲤鱼<br>
	<input type="checkbox" name="chi" value="草鱼">草鱼<br>
	<input type="checkbox" name="chi" value="鲢鱼">鲢鱼<br>
	<input type="checkbox" name="chi" value="鳙鱼">鳙鱼<br>
	<input type="radio" name="aihao" value="chi">吃
	<input type="radio" name="aihao" value="he">喝
	<input type="radio" name="aihao" value="wan">玩
	<input type="radio" name="aihao" value="le">乐
	<select name="xuan">
		<option value="guo">中</option>
		<option value="mei">美</option>
		<option value="ying">英</option>
	</select>
	<input type="submit" />
	<input type="button" onclick="en()">
</form>
<hr>
<!-- 
	1.form表单提交,当前form表单中的name属性为参数名称,value属性为参数值
	2.超链接提交,通过href属性来决定当前的提交地址,在地址后可以携带参数,可以携带多个参数
	注意:在form表单中,action属性也可以完成参数传递,传递方法同超链接方式的提交,接收方式也是getParameter(参数名称),method属性必须是post
 -->
<a href="<%=path %>/args/newJieForm.jsp?name=kitty&age=5">点我</a>
<Input type="button" onclick="on()">
</body>
</html>